package com.cxria.pattern.memento.func2

def originator = new Originator2()

originator.state = 'a'

println originator.state

originator.createMemento()

originator.state = 'b'

println originator.state

originator.restoreMemento()

println originator.state